<?php
    require_once($_SERVER["DOCUMENT_ROOT"]."/admin_panel/include/cookie.php");
    $cookie = array(
        "token"
    );
    Remove_Cookie($cookie);
?>
<!doctype html>

<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="robots" content="noindex, nofollow">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="A layout example that shows off a blog page with a list of posts.">
    <title>Змей Горыныч</title>

    <link rel="stylesheet" href="assets/css/pure-min.css">
    <link rel="stylesheet" href="assets/css/pure-responsive-min.css">
    <link rel="stylesheet" href="assets/css/style.css">
</head>
<body>
    <div id="main" class="pure-g">
        <div class="sidebar pure-u-1 pure-u-md-1-2" style="background-image: url('zmei.png')">
            <div class="header-large">
                <nav class="nav">
            </div>
        </div>

        <div class="content pure-u-1 pure-u-md-1-2">
            <div class="header-medium">

                <div class="items">
                    <h1 class="subhead">Login</h1>
                    <h1 style="background-color: rgb(135, 137, 156); opacity: 0.8; color:rgb(5, 5, 5);">Административная панель виртуального  хостинга "Змей Горыныч"</h1>

                    <?php
                        if (isset($_GET['error'])) {
                            if ($_GET['error'] == 1)
                                echo '
                                        <aside class="pure-message message-error">
                                            <p><strong>ERROR</strong>: Wrong login or password.</p>
                                        </aside>';
                            elseif ($_GET['error'] == 2)
                                echo '
                                <aside class="pure-message message-error">
                                    <p><strong>ERROR</strong>: Something wrong.</p>
                                </aside>';
                            elseif ($_GET['error'] != "")
                                echo '
                                <aside class="pure-message message-error">
                                    <p><strong>ERROR</strong>: Unknown password.</p>
                                </aside>';
                        }
                    ?>
                    <form action="login.php" method="post" class="pure-form pure-form-stacked">
                        <fieldset>

                            <label for="login">Имя пользователя</label>
                            <input id="login" name="login" type="text" placeholder="Login" class="pure-input-1" value="" required>

                            <label for="password">Пароль</label>
                            <input id="password" name="password" type="password" placeholder="Password" class="pure-input-1" value="" required>


                            <button type="submit" class="pure-button button-success">Войти</button>
                        </fieldset>
                    </form>
                </div>

                <div class="footer">
                    <div class="pure-menu pure-menu-horizontal">
                    </div>
                </div>
            </div>
        </div>
    </div>
</body>
</html>
